/**
 * eCommerce Application Sample for J2EE Training
 * Remote interface for the EcomCustomer bean
 * EJB3.0
 * @author Fabienne Boyer - Didier Donsez - may 2006
 */
package ecom.session;

import ecom.cart.CartItem;
import ecom.cart.CartLocal;
import ecom.entity.Adress;
import ecom.entity.Category;
import ecom.entity.Country;
import ecom.entity.Customer;
import ecom.entity.Product;
import ecom.entity.ProductStore;
import ecom.entity.Store;
import ecom.exception.EcomException;
import java.util.List;

public interface EcomCustomerRemote {

    Product findProductById(int productId);

    List<Product> listProducts();

    Product findProductByName(String name);

    List<Product> findProductsByInName(String inName);

    List<Product> findProductsByMaxPrice(Double maxPrice);

    List<ProductStore> listProductsStore(int idStore);

    List<Product> listProductsByCategory(int idCategory);
    
    List<Store> listStore();

    List<Country> listCountry();

//    List<CartItem> listProductCart(CartLocal cart);
//    
//    List<CartItem> listProductInCart();

    List<Category> listCategories();
    
    List<Store> listStores ();
    
    void deposit(String Iban, Double amount);

//    void addProductToCart(Product product, double price, int storeId);

    double getBalanceCustomer(Customer customer);

    Customer login(String email, String password);

    void purchase(List<CartItem> cartItems, Customer customer, Adress adress) throws EcomException;

    Customer addAdressToCustomer(Adress adress, Customer customer);

    Adress findAdressById(int id);
}
